Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUGFIX] Split $objectDefinition into $schema and $properties #411

Merged

Conversation

erayd
Copy link
Contributor

@erayd erayd commented Apr 11, 2017

What

Why

Object validation attempts to use a single variable to store both the object schema, and the definition of the object's properties. This causes validation to be incomplete where "properties" is not set, but "additionalProperties" is.

Object validation attempts to use a single variable to store both the
object definition, and its properties. This causes validation to be
incomplete where "properties" is not set, but "additionalProperties" is.

This commit fixes both bugs in issue jsonrainbow#353.
@erayd erayd mentioned this pull request Apr 11, 2017
@erayd erayd changed the title Split $objectDefinition into $schema and $properties [BUGFIX] Split $objectDefinition into $schema and $properties Apr 11, 2017
Copy link
Collaborator

@bighappyface bighappyface left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 for 7fc4bf4

@bighappyface
Copy link
Collaborator

@o5 @shmax @mathroc may I have your help giving this another review?

@bighappyface bighappyface merged commit 7ec8f1b into jsonrainbow:6.0.0-dev Apr 11, 2017
@erayd erayd deleted the bugfix-353-additional-properties branch April 11, 2017 20:54
erayd added a commit to erayd/json-schema that referenced this pull request Apr 11, 2017
Object validation attempts to use a single variable to store both the
object definition, and its properties. This causes validation to be
incomplete where "properties" is not set, but "additionalProperties" is.

This commit fixes both bugs in issue jsonrainbow#353.
@erayd erayd mentioned this pull request Apr 11, 2017
@shmax
Copy link
Collaborator

shmax commented Apr 13, 2017

Whoops, sorry guys--I'm still paying attention and still interested, but this one just slipped past my radar. Holler if you need anything.

bighappyface pushed a commit that referenced this pull request May 16, 2017
* Split $objectDefinition into $schema and $properties (#411)

Object validation attempts to use a single variable to store both the
object definition, and its properties. This causes validation to be
incomplete where "properties" is not set, but "additionalProperties" is.

This commit fixes both bugs in issue #353.

* Issue-414: Allow The Option of T or space for Date time. (#415)

* Testcase for minProperties with properties defined (#416)

+ Fix Test

* Tweak phpdocumentor dependency to avoid install conflicts (#421)

* [BUGFIX] Cast empty schema arrays to object (#409)

* Cast root to object

* Use function_exists to allow polyfill compatibility

* Move array->object conversion to SchemaConstraint & SchemaStorage

Fixes issue #408

* fix bug when applying defaults for array items when the schema is for (#405)

all items and add support for minItems when applying defaults

* [BUGFIX] Split "uri" format into "uri" & "uri-reference", fix meta-schema bug (#419)

* Split "uri" format into "uri" and "uri-reference"

* Correct format for id & $ref in draft-03/04 meta-schemas

See json-schema-org/JSON-Schema-Test-Suite#177 (comment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants